import Layout from '@/layout';
const meta = {
	auth: true
};
const _import = require('@/utils/util.import.' + process.env.NODE_ENV);

export default {
	path: '/pdm',
	component: Layout,
	name: 'pdm',
	meta,
	redirect: { 
		name: 'pdm_material_manage'
	},
	children: (pre => [{
			path: 'material_manage/maintain',
			name: `${pre}material_manage`,
			component: _import('modules/pdm/material_manage/maintain.vue'),
			meta: {
				...meta,
				title: '存货编码维护'
			},

		},
		{
				path: 'material_manage/miantain_type',
				name: `${pre}miantain_type`,
				component: _import('modules/pdm/material_manage/miantain_type.vue'),
				meta: {
					...meta,
					title: '存货分类维护'
				},
		
			},
		{
			path: 'document_maintain/bom_basic',
			name: `${pre}document_maintain_bom_basic`,
			component: _import('modules/pdm/document_maintain/bom_basic.vue'),
			meta: {
				...meta,
				title: '基础BOM'
			},

		},
		// {
		// 	path: 'document_maintain/bom_model',
		// 	name: `${pre}document_maintain_bom_model`,
		// 	component: _import('modules/pdm/document_maintain/bom_model.vue'),
		// 	meta: {
		// 		...meta,
		// 		title: '模板BOM'
		// 	},
		// },
		{
			path: 'document_maintain/edit_mechanical_info',
			name: `${pre}document_maintain_edit_mechanical_info`,
			component: _import('modules/pdm/document_maintain/edit_mechanical_info.vue'),
			meta: {
				...meta,
				title: '项目机械维护'
			},
		},
		{
			path: 'document_maintain/edit_electrical_info',
			name: `${pre}document_maintain_edit_electrical_info`,
			component: _import('modules/pdm/document_maintain/edit_electrical_info.vue'),
			meta: {
				...meta,
				title: '项目电控维护'
			},
		},
		{
			path: 'document_maintain/edit_software_info',
			name: `${pre}document_maintain_edit_software_info`,
			component: _import('modules/pdm/document_maintain/edit_software_info.vue'),
			meta: {
				...meta,
				title: '项目软件维护'
			},
		},
		{
			path: 'document_maintain/project_audit',
			name: `${pre}document_maintain_project_audit`,
			component: _import('modules/pdm/document_maintain/project_audit.vue'),
			meta: {
				...meta,
				title: '项目需求审核'
			},
		},
		{
			path: 'document_maintain/design_audit_mechanical',
			name: `${pre}document_maintain_design_audit_mechanical`,
			component: _import('modules/pdm/document_maintain/design_audit_mechanical.vue'),
			meta: {
				...meta,
				title: '项目机械审核'
			},
		},
		{
			path: 'document_maintain/design_audit_electrical',
			name: `${pre}document_maintain_design_audit_electrical`,
			component: _import('modules/pdm/document_maintain/design_audit_electrical.vue'),
			meta: {
				...meta,
				title: '项目电气审核'
			},
		},
		{
			path: 'document_maintain/design_audit_software',
			name: `${pre}document_maintain_design_audit_software`,
			component: _import('modules/pdm/document_maintain/design_audit_software.vue'),
			meta: {
				...meta,
				title: '项目软件审核'
			},
		},
		{
			path: 'project_relation/info_manage',
			name: `${pre}project_relation_info_manage`,
			component: _import('modules/pdm/project_relation/info_manage.vue'),
			meta: {
				...meta,
				title: '项目需求导入'
			},
		},
		{
			path: 'project_relation/document_history',
			name: `${pre}project_relation_document_history`,
			component: _import('modules/pdm/project_relation/document_history.vue'),
			meta: {
				...meta,
				title: '历史项目图纸'
			},
		},
		{
			path: 'project_relation/purchase_need',
			name: `${pre}project_relation_purchase_need`,
			component: _import('modules/pdm/project_relation/purchase_need.vue'),
			meta: {
				...meta,
				title: '采购需求查看'
			},
		},

	])('pdm_')
};
